{% include 'header.html' %}

<div id="code"></div>



<script type="text/javascript">


    $(function () {

        var data = '{{  data | safe }}';
        $('#code').qrcode(data);
    })

    function quire() {
        $.ajax({
            url: "/services/validate/{{ req_id }}/", async: false, success: function (result) {
                console.log(result);
                if (result['errors'] == 0) {
                    $('#code').html('注册成功')
                }
            }
        })
    }
    setInterval("quire()", 5000);
</script>

{% include 'footer.html' %}
